package com.cloudfun.campusshare.repo;

import com.cloudfun.campusshare.entity.DeviceServiceTimeEntity;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

import java.util.Collection;
import java.util.List;

/**
 * @author : zhangyongjie
 * @version : 1.0
 * @createTime : 2020/5/9 11:01
 * @description :
 */
@Repository
public interface DeviceServiceTimeEntityRepo extends JpaRepository<DeviceServiceTimeEntity, String>, JpaSpecificationExecutor<DeviceServiceTimeEntity> {
    DeviceServiceTimeEntity findByIdAndMerchantId(String id,String merchantId);

    DeviceServiceTimeEntity findByIdAndCreatorIdIn(String id, Collection<String> ids);

    DeviceServiceTimeEntity findByIdAndWashPointId(String id,String washPointId);

    List<DeviceServiceTimeEntity> findAllByWashPointId(String washPointId);

}
